package com.yc.fruitmarket.biz.impl;

import java.util.List;
import java.util.Map;

import com.yc.fruitmarket.biz.discountcardBiz;
import com.yc.fruitmarket.dao.DBHelper;

public class discountcardBizImpl implements discountcardBiz {
	private DBHelper db = new DBHelper();

	@Override
	public List<Map<String, String>> getDiscount(String did) {
		if("".equals(did)) {
			return null;
		}
		String sql = " select * from discountcard where did = ?";
		return db.find(sql, did);
	}

	@Override
	public List<Map<String, String>> findDiscountcard(String uid) {
		String sql = "select * from discountcard where status = 1 and uid = ?";
		return db.find(sql, uid);
	}
	
}
